//
//  YZArchieveOptionCell.m
//  VET
//
//  Created by 刘文靖 on 2018/7/15.
//  Copyright © 2018年 YZ. All rights reserved.
//

#import "YZArchieveOptionCell.h"
#import "YZOptionBtn.h"
#import "YZWorkNoteModel.h"
#import "YZPigModel.h"
#import "YZSwineryModel.h"
//#import "YZLineView.h"
@interface YZArchieveOptionCell()

@end
@implementation YZArchieveOptionCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self){
        self.selectionStyle = UITableViewCellSelectionStyleNone;
        self.contentView.backgroundColor = kColorWithHex(0xffffff);
        self.optionBtn = [[YZOptionBtn alloc] init];
        self.optionBtn.userInteractionEnabled = NO;
        [self.contentView addSubview:self.optionBtn];
        [self.optionBtn  mas_makeConstraints:^(MASConstraintMaker *make) {
            make.edges.offset(0);
        }];
    }
    return self;
}

- (void)setArchieveModel:(id)archieveModel{
    _archieveModel = archieveModel;
    if ([archieveModel isKindOfClass:[YZArchiveModel class]]) {
        self.optionBtn.descStr = [archieveModel optionStr];
    }else if ([archieveModel isKindOfClass:[YZPigModel class]]){
        self.optionBtn.descStr = [archieveModel pigOptionStr];
    }else{
        self.optionBtn.descStr = [archieveModel swineryOptionStr];
    }
    
}

@end
